<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>暠雨</title>
    <link rel="stylesheet" href="__STATIC__/index/css/base.css">
    <link rel="stylesheet" href="__STATIC__/index/css/style.css">
    <link href="__STATIC__/admin/assets/css/bootstrap.min.css" rel="stylesheet" />
    <script src="__STATIC__/admin/js/jquery-1.9.1.min.js"></script>
    <script src="__STATIC__/admin/js/bootstrap.min.js"></script>
</head>

<body>
<div class="head-box">
    <div class="head wrap">
        <div class="logo fl"><a href=""><img src="__STATIC__/index/images/logo.png"></a></div>
        <div class="head-right fr">
            <div class="head-a fr">
                <div class="hgt fl"><img src="__STATIC__/index/images/hgt.png">
                    <div class="hgt-top">
                        <input type="text" class="hgt-text">
                    </div>
                </div>
                {if condition='$user'}
                <div class="head-a1 fl"><a href=""><img src="__STATIC__/index/images/tb-a.png"></a></div>
                <div class="head-a1 fl"><a href=""><img src="__STATIC__/index/images/tb-b.png"></a></div>
                <div class="tbt fl"><img src="__UPLOAD__/user/{$user.image_thumb}" style="width: 30px;">
                    <div class="hgt-btm">
                        <a href="{:url('user/collection',['user_id'=>$user.user_id])}">我的主页</a>
                        <a href="">消息</a>
                        <a href="{:url('user/account',['user_id'=>$user.user_id])}">帐号设置</a>
                        <a href="{:url('user/logon')}">退出</a>
                    </div>
                </div>

                {else}
                <div class="head-a1 fl"><a href=""><img src="__STATIC__/index/images/tb-a.png"></a></div>
                <div class="head-a1 fl"><a href=""><img src="__STATIC__/index/images/tb-b.png"></a></div>
                <div class="head-a3 fl"><a href="{:url('login/index')}">登录</a></div>
                <div class="head-a4 fl"><a href="{:url('login/login')}">注册</a></div>
                {/if}

            </div>
            <div class="clearfix"></div>
            <div class="nav fr">
                <ul>
                    <li><a href="{:url('index/index')}">首页</a></li>
                    <li class="nav-cut"><a href="{:url('question/article')}">文章</a>
                    </li>
                </ul>
            </div>
            <div class="clearfix"></div>
        </div>
    </div>
</div>

<div class="content">
    <div class="wrap">
        <div class="art-height"></div>
        <div class="art-box">
            <div class="art-c">
                <div class="art-fl fl">
                    <div class="ru-title art-title">
                        <div class="cou-b1"><img src="images/cou-b1.jpg">当前文章</div>
                        <div class="ru-a1">
                            <div class="sort">排序</div>
                        </div>
                        <div class="ru-a2">
                            <div class="dropdown">
                                <span>情感</span>
                                <ul data-value="" class="droplist">
                                    <li data-id="1">全部</li>
                                    <li data-id="2">服饰</li>
                                    <li data-id="3">最新</li>
                                    <li data-id="4">提问</li>
                                    <li data-id="5">约会技巧</li>
                                    <li data-id="6">热门文章</li>
                                </ul>
                            </div>
                        </div>
                    </div>
                    <div class="tjk">
                        <ul class="art-ul">

                            {foreach $questions as $item}
                            <a href="{:url('question/question',['q_id'=>$item.q_id,'user_id'=>$user.user_id])}">
                                <li>
                                    <div class="art-list">
                                        <div class="art-d fl"><img src="__UPLOAD__/question/{$item.image_thumb}"></div>
                                        <div class="art-e fl">
                                            <div class="col-b1">{$item.q_title}</div>
                                            <div class="col-b2">{$item.user_id}<span>{$item.create_time|date="Y-m-d H:i:s",###}发布</span></div>
                                        </div>
                                        <div class="art-f">
                                            <span><img src="__STATIC__/index/images/col-c1.jpg">0</span>
                                            <span><img src="__STATIC__/index/images/col-c2.jpg">3</span>
                                            <em><img src="__STATIC__/index/images/col-c3.jpg"></em>
                                            <em><img src="__STATIC__/index/images/col-c4.jpg"></em>
                                            <em><img src="__STATIC__/index/images/col-c5.jpg"></em>
                                        </div>
                                    </div>
                                    <div class="art-g"></div>
                                </li>
                            </a>
                            {/foreach}
                        </ul>
                    </div>
                    <div class="row">

                        <div class="col-sm-6">
                            <div class="dataTables_info">{$questions->render()}</div>
                        </div>
                    </div>

                </div>

                <div class="post-fr fr">
                    <div class="post-y">
                        <div class="ru-c1" style="margin-bottom: 20px"><a href="{:url('question/add',['user_id'=>$user.user_id])}"> 发表帖子</a></div>

                        <div class="post-y1"><img src="__STATIC__/index/images/cou-b1.jpg">热门帖子</div>
                        <ul>
                            {foreach $coll_ques as $item}
                            <a href="{:url('question/question',['q_id'=>$item.q_id,'user_id'=>$user.user_id])}"><li>
                                <div class="post-y2"><img src="__UPLOAD__/question/{$item.image_thumb}"></div>
                                <div class="post-y3">{$item.q_title} <span>{$item.click}点击</span></div>
                                <div class="post-y3" ><span style="color:red;">{$item.user_name}</span> <span>{$item.create_time|date="Y-m-d H:i:s",###}发表</span></div>

                            </li></a>
                            {/foreach}
                        </ul>
                    </div>
                </div>
            </div><!--art-c-->

        </div>
    </div>
</div>

<div class="footer">
    <div class="wrap">
        <div class="foot">
            <div class="foot-left fl">
                <a href="">关于我们</a>
                <a href="">加入我们</a>
                <a href="contact.html">联系我们</a>
                <a href="">媒体采访</a>
            </div>
            <div class="foot-c fl"><a href=""><img src="__STATIC__/index/images/foot-logo.jpg"></a></div>
            <div class="foot-right fr">
                <a href="">同城活动</a>
                <a href="">课程资讯</a>
                <a href="">最新发布</a>
                <a href="">热门文章</a>
            </div>
        </div>

    </div>
</div>
<script src="__STATIC__/index/js/Action.js"></script>
<script>
    $(".sort").click(function () {
        $(this).toggleClass("sort-cut")
    })
</script>
<script>
    $(".dropdown").bind({
        click: function () {
            $(this).find(".droplist").stop().slideDown();
        },
        mouseleave: function () {
            $(this).find(".droplist").hide();
        }
    });
    $(".dropdown .droplist li").click(function () {
        $(this).parents(".dropdown").children("span").text($(this).text());
        $(this).parents(".droplist").hide().attr("data-value", $(this).attr("data-id"));
    });
</script>

</body>
</html>

